#include "stdafx.h"

#include "SHFuturesDefine.h"

namespace CTPAPI {



	char * getCharFromString(String * sStr)
	{
		IntPtr sptr = System::Runtime::InteropServices::Marshal::StringToHGlobalAnsi(sStr);
		void* stemp = sptr.ToPointer();
		char* szStr = static_cast<char*>(stemp);

		return szStr;
	}

	String * getStringFromChar(char * sStr)
	{
		String * szStr = System::Runtime::InteropServices::Marshal::PtrToStringAnsi(System::IntPtr::IntPtr((void *) sStr));

		return szStr;
	}
}